<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%@ page contentType="text/html;charset=utf-8" language="java" %>
<!DOCTYPE HTML>
<html lang="zh-cn">
<head>
    <meta charset="UTF-8">
    <title>审核</title>
    <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no">
    <link rel="stylesheet" href="https://at.alicdn.com/t/font_289760_kjgrg5zwme9g4x6r.css">
    <link rel="stylesheet" href="lib/bootstrap-3.3.7/dist/css/bootstrap.css">
    <link rel="stylesheet" href="css/public.css">
    <link href="<c:url value="/css/style3.css"/>" rel="stylesheet"/>
    <script src="lib/jquery/jquery-3.2.1.min.js"></script>
    <script src="lib/bootstrap-3.3.7/dist/js/bootstrap.js"></script>

</head>
<body>
<div class="container">
        <div class="main">
            <div class="suv-title">
                <p class="suvTitle"><c:out value="${questionnaire.title}"/></p>
                <p class="welcome">感谢您能抽出几分钟时间来参加本次答题，现在我们就马上开始吧！</p>
            </div>
            <div class="text-group">
                    <c:forEach var="question" items="${questionList}">
                    <c:if test="${question.type eq 'SChoice'}">
                    <div class="radio-group">
                        <p> <c:out value="${question.questionNum}"/>. <c:out value="${question.content}"/></p>
                        <c:forEach var="option" items="${optionList}">
                            <c:if test="${option.questionId == question.questionId}">
                                <div class="radio">
                                    <input type="radio" id="radio-1" name="radio1" value="${option.content}">
                                    <label for="radio-1"><c:out value="${option.content}"/></label>
                                </div>
                            </c:if>
                        </c:forEach>
                    </div>
                    </c:if>
                    <c:if test="${question.type eq 'Blank'}">
                    <p> <c:out value="${question.questionNum}"/>. <c:out value="${question.content}"/></p>
                    <input type="text" name="radio3" disabled style="width: 100%">
                    </c:if>
                    <c:if test="${question.type eq 'MChoice'}">
                    <div class="checkbox-group">
                        <p> <c:out value="${question.questionNum}"/>. <c:out value="${question.content}"/></p>
                        <c:forEach var="option" items="${optionList}">
                            <c:if test="${option.questionId == question.questionId}">
                                <div class="checkbox">
                                    <input type="checkbox" id="checkbox-1" name="radio2" value="${option.content}">
                                    <label for="checkbox-1"><c:out value="${option.content}"/></label>
                                </div>
                            </c:if>
                        </c:forEach>
                    </div>
                    </c:if>
                    </c:forEach>
            </div>
            <input type="submit" class="submit" value="通过" onclick="check1()" >

            <input type="submit" class="submit" value="不通过" onclick="check2()">

            <input type="submit" class="submit" value="返回" onclick="check3()">
        </div>

</div>
<div class="main-show-mb">
    <div class="tips">
        您已完成本次问卷，感谢您的帮助与支持
    </div>
</div>
<script type="text/javascript">
    function check1() {
        window.location.href = "/manager/editState"
    }
    function check2() {
        window.location.href = "/manager/editState2"
    }
    function check3() {
        window.location.href = "/manager/managers/allSurvey?act1=back"
    }
</script>
</body>
</html>